﻿using System;
using System.Collections.Generic;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Entity;
using System.Data;
using BusinessObject;

namespace GreenLife
{
    public partial class ChiTietTinTuc : System.Web.UI.Page
    {
        DataSet ds;
        News n;
        NewsBO nBO = new NewsBO();
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                selectNewByID();
            }
        }
        public void selectNewByID()
        {
            n = new News();
            int id = Int32.Parse(Request.QueryString["id"]);
            n = nBO.selectNewByID(id);
            lbTitle.Text = n.New_Title.ToString();
            QT.InnerText = n.New_QuickTitle.ToString();
            imgNews.ImageUrl = n.New_Image.ToString();
            content.Text = n.New_Content.ToString();
        }
    }
}